﻿@model List<CampDay20.Models.Student>

<br />
<a href="/Home/CreateStudent">Create New Student</a>
<table class="table table-bordered">
    <thead>
        <tr>
            <th>First Name</th>
            <th>Last Name</th>
            <th>Grade Level</th>
            <th>Buttons</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var s in Model)
        {
            <tr>
                <td><a href="/Home/Student/@s.Id">@s.FirstName</a></td>
                <td>@s.LastName</td>
                <td>@s.Grade</td>
                <td>
                    <a href="/Home/EditStudent/@s.Id" class="btn btn-warning">Edit</a>
                    <a href="/Home/DeleteStudent/@s.Id" class="btn btn-danger">Delete</a>
                </td>
            </tr>
        }
    </tbody>
</table>